package com.xmg.design23.d5_adapter;

/**
 * @Author: mazhongqing
 * @Date: 2021/3/24 15:49
 */
public class Test {
    public static void main(String[] args) {
        int volt = new HomeBattery().supply();
//        new USBLine().charge(volt); //此处会报错

        new USBLine().charge(new Adapter().convert(volt)); //转换之后 正常充电

    }
}
